.settings-panel {
  height: 100%;
  overflow-y: auto;
  background-color: #ffffff;
}

.settings-header {
  padding: 24px 24px 16px 24px;
  border-bottom: 1px solid #e9ecef;
  background-color: #f8f9fa;
}

.settings-header h2 {
  margin: 0 0 4px 0;
  font-size: 24px;
  font-weight: 600;
  color: #2c3e50;
}

.settings-header p {
  margin: 0;
  color: #6c757d;
  font-size: 14px;
}

.settings-content {
  padding: 24px;
}

.settings-section {
  margin-bottom: 32px;
}

.settings-section:last-child {
  margin-bottom: 0;
}

.settings-section h3 {
  margin: 0 0 16px 0;
  font-size: 18px;
  font-weight: 600;
  color: #495057;
  border-bottom: 2px solid #007acc;
  padding-bottom: 8px;
}

.setting-item {
  margin-bottom: 20px;
}

.setting-item:last-child {
  margin-bottom: 0;
}

.setting-item label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: #495057;
  font-size: 14px;
}

.setting-select,
.setting-input {
  width: 100%;
  max-width: 300px;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
  background-color: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.setting-select:focus,
.setting-input:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 2px rgba(0, 122, 204, 0.1);
}

.model-select-container {
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 300px;
}

.model-select-container .setting-select {
  flex: 1;
  max-width: none;
}

.add-model-button {
  background-color: #007acc;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  min-width: 60px;
}

.add-model-button:hover:not(:disabled) {
  background-color: #0056a3;
}

.add-model-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.setting-description {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: #6c757d;
  line-height: 1.4;
}

.about-info {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 20px;
  border: 1px solid #e9ecef;
}

.about-info p {
  margin: 0 0 8px 0;
  color: #495057;
}

.about-info p:last-of-type {
  margin-bottom: 16px;
}

.about-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.link-button {
  background-color: #007acc;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.link-button:hover {
  background-color: #0056b3;
  transform: translateY(-1px);
}

/* Persona Container Styles */
.persona-container {
  margin-top: 20px;
}

/* Persona Display Mode Styles */
.persona-display-mode {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 8px;
}

.persona-display-text {
  flex: 1;
  padding: 12px 16px;
  background-color: #f8f9fa;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.5;
  color: #374151;
  min-height: 80px;
  max-height: 120px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.edit-persona-btn {
  background: linear-gradient(135deg, #007acc, #0056b3);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 122, 204, 0.2);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.edit-persona-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #0056b3, #004494);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 122, 204, 0.3);
}

.edit-persona-btn:disabled {
  background: linear-gradient(135deg, #9ca3af, #6b7280);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Persona Edit Mode Styles */
.persona-edit-mode {
  margin-top: 16px;
  padding: 20px;
  background-color: #f8f9fa;
  border: 2px solid #e9ecef;
  border-radius: 8px;
}

.persona-template-selector {
  margin-bottom: 20px;
}

.persona-template-selector label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: #495057;
  font-size: 14px;
}

.persona-text-editor {
  margin-bottom: 20px;
}

.persona-text-editor label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: #495057;
  font-size: 14px;
}

.persona-textarea {
  width: 100%;
  min-height: 120px;
  padding: 12px;
  border: 2px solid #e1e5e9;
  border-radius: 8px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  line-height: 1.5;
  background-color: #ffffff;
  color: #374151;
  resize: vertical;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  box-sizing: border-box;
}

.persona-textarea:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.1);
}

.persona-textarea::placeholder {
  color: #6b7280;
  font-style: italic;
}

.persona-edit-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.save-persona-btn {
  background: linear-gradient(135deg, #28a745, #20c997);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(40, 167, 69, 0.2);
  display: flex;
  align-items: center;
  gap: 6px;
}

.save-persona-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #218838, #1e7e34);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(40, 167, 69, 0.3);
}

.save-persona-btn:disabled {
  background: linear-gradient(135deg, #9ca3af, #6b7280);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.cancel-persona-btn {
  background: #6c757d;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.cancel-persona-btn:hover:not(:disabled) {
  background: #5a6268;
  transform: translateY(-1px);
}

.cancel-persona-btn:disabled {
  background: #adb5bd;
  cursor: not-allowed;
  transform: none;
}

.update-message {
  font-size: 13px;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.update-message.success {
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.update-message.error {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.update-message.info {
  background-color: #eff6ff;
  color: #1e40af;
  border: 1px solid #93c5fd;
}

/* Disabled states */
.setting-select:disabled,
.persona-textarea:disabled {
  background-color: #f3f4f6;
  color: #6b7280;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Dark mode support for persona interface */
@media (prefers-color-scheme: dark) {
  .persona-display-text {
    background-color: #374151;
    border-color: #4b5563;
    color: #f9fafb;
  }
  
  .persona-edit-mode {
    background-color: #374151;
    border-color: #4b5563;
  }
  
  .persona-textarea {
    background-color: #1f2937;
    border-color: #4b5563;
    color: #f9fafb;
  }
  
  .persona-textarea:focus {
    border-color: #007acc;
    box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.2);
  }
  
  .persona-textarea::placeholder {
    color: #9ca3af;
  }
  
  .persona-template-selector label,
  .persona-text-editor label {
    color: #f9fafb;
  }
  
  .update-message.success {
    background-color: #064e3b;
    color: #a7f3d0;
    border-color: #065f46;
  }
  
  .update-message.error {
    background-color: #7f1d1d;
    color: #fecaca;
    border-color: #991b1b;
  }
  
  .update-message.info {
    background-color: #1e3a8a;
    color: #93c5fd;
    border-color: #1e40af;
  }
  
  .setting-select:disabled,
  .persona-textarea:disabled {
    background-color: #374151;
    color: #6b7280;
  }
}

/* Responsive design */
@media (max-width: 768px) {
  .settings-content {
    padding: 16px;
  }
  
  .settings-header {
    padding: 16px;
  }
  
  .setting-select,
  .setting-input {
    max-width: 100%;
  }
  
  .about-links {
    flex-direction: column;
  }
  
  .link-button {
    justify-content: center;
  }
  
  /* Persona responsive styles */
  .persona-display-mode {
    flex-direction: column;
    gap: 12px;
  }
  
  .persona-display-text {
    min-height: 60px;
    max-height: 100px;
  }
  
  .edit-persona-btn {
    align-self: flex-start;
  }
  
  .persona-edit-mode {
    padding: 16px;
  }
  
  .persona-edit-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  
  .save-persona-btn,
  .cancel-persona-btn {
    justify-content: center;
  }
}

/* API Key Management Styles */
.api-key-actions {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 8px;
  margin-bottom: 8px;
}

.api-key-check-btn {
  background: linear-gradient(135deg, #059669, #047857);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(5, 150, 105, 0.2);
  display: flex;
  align-items: center;
  gap: 8px;
}

.api-key-check-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #047857, #065f46);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(5, 150, 105, 0.3);
}

.api-key-check-btn:disabled {
  background: linear-gradient(135deg, #9ca3af, #6b7280);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.api-key-update-btn {
  background: linear-gradient(135deg, #059669, #047857);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(5, 150, 105, 0.2);
  display: flex;
  align-items: center;
  gap: 8px;
}

.api-key-update-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #047857, #065f46);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(5, 150, 105, 0.3);
}

.api-key-update-btn:disabled {
  background: linear-gradient(135deg, #9ca3af, #6b7280);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Dark mode support for API key styles */
@media (prefers-color-scheme: dark) {
  .api-key-check-btn {
    background: linear-gradient(135deg, #065f46, #047857);
  }
  
  .api-key-check-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #047857, #059669);
  }
  
  .api-key-update-btn {
    background: linear-gradient(135deg, #065f46, #047857);
  }
  
  .api-key-update-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #047857, #059669);
  }
}

/* MCP Marketplace Styles */
.mcp-marketplace {
  background-color: #ffffff !important;
  background: #ffffff !important;
  border-radius: 8px;
  padding: 20px;
  border: 1px solid #e9ecef !important;
  color: #212529 !important;
}

.mcp-controls {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.mcp-search {
  flex: 1;
  min-width: 200px;
}

.mcp-search-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
  background-color: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.mcp-search-input:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 2px rgba(0, 122, 204, 0.1);
}

.mcp-filter {
  min-width: 120px;
}

.mcp-category-select {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
  background-color: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.mcp-category-select:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 2px rgba(0, 122, 204, 0.1);
}

.mcp-message {
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 500;
}

.mcp-message.success {
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.mcp-message.error {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.mcp-message.info {
  background-color: #eff6ff;
  color: #1e40af;
  border: 1px solid #93c5fd;
}

.mcp-loading {
  text-align: center;
  padding: 20px;
  color: #6c757d;
  font-style: italic;
}

.mcp-servers-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.mcp-server-item {
  background-color: #ffffff;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 16px;
  transition: all 0.2s ease;
}

.mcp-server-item:hover {
  border-color: #007acc;
  box-shadow: 0 2px 8px rgba(0, 122, 204, 0.1);
}

.mcp-server-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  gap: 16px;
}

.mcp-server-info {
  flex: 1;
  min-width: 0;
}

.mcp-server-name {
  margin: 0 0 4px 0;
  font-size: 16px;
  font-weight: 600;
  color: #2c3e50;
}

.mcp-server-category {
  display: inline-block;
  background-color: #007acc;
  color: white;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-right: 8px;
}

.mcp-connected-badge {
  display: inline-block;
  background-color: #28a745;
  color: white;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 500;
}

.mcp-server-actions {
  flex-shrink: 0;
}

.mcp-connect-btn,
.mcp-disconnect-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.mcp-connect-btn {
  background-color: #28a745;
  color: white;
}

.mcp-connect-btn:hover:not(:disabled) {
  background-color: #218838;
  transform: translateY(-1px);
}

.mcp-disconnect-btn {
  background-color: #dc3545;
  color: white;
}

.mcp-disconnect-btn:hover:not(:disabled) {
  background-color: #c82333;
  transform: translateY(-1px);
}

.mcp-connect-btn:disabled,
.mcp-disconnect-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.mcp-server-description {
  margin: 0 0 12px 0;
  color: #6c757d;
  font-size: 14px;
  line-height: 1.5;
}

.mcp-server-details {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 12px;
}

.mcp-author {
  color: #495057;
  font-weight: 500;
}

.mcp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.mcp-tag {
  background-color: #e9ecef;
  color: #495057;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
}

.mcp-requirements {
  color: #6c757d;
  font-size: 11px;
}

.mcp-github-link {
  color: #007acc;
  text-decoration: none;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.mcp-github-link:hover {
  color: #0056b3;
  text-decoration: underline;
}

.mcp-no-results {
  text-align: center;
  padding: 40px 20px;
  color: #6c757d;
  font-style: italic;
}

/* Force light theme for MCP marketplace in dark mode */
@media (prefers-color-scheme: dark) {
  .mcp-marketplace {
    background-color: #ffffff !important;
    background: #ffffff !important;
    border-color: #e9ecef !important;
    color: #212529 !important;
  }
  
  .mcp-marketplace .mcp-search-input,
  .mcp-marketplace .mcp-category-select {
    background-color: #ffffff !important;
    border-color: #ced4da !important;
    color: #495057 !important;
  }
  
  .mcp-marketplace .mcp-search-input:focus,
  .mcp-marketplace .mcp-category-select:focus {
    border-color: #007acc !important;
    box-shadow: 0 0 0 2px rgba(0, 122, 204, 0.1) !important;
  }
  
  .mcp-marketplace .mcp-server-item {
    background-color: #ffffff !important;
    border-color: #e9ecef !important;
  }
  
  .mcp-marketplace .mcp-server-item:hover {
    border-color: #007acc !important;
    box-shadow: 0 2px 8px rgba(0, 122, 204, 0.1) !important;
  }
  
  .mcp-marketplace .mcp-server-name {
    color: #2c3e50 !important;
  }
  
  .mcp-marketplace .mcp-server-description {
    color: #6c757d !important;
  }
  
  .mcp-marketplace .mcp-author {
    color: #495057 !important;
  }
  
  .mcp-marketplace .mcp-tag {
    background-color: #e9ecef !important;
    color: #495057 !important;
  }
  
  .mcp-marketplace .mcp-requirements {
    color: #6c757d !important;
  }
  
  .mcp-marketplace .mcp-github-link {
    color: #007acc !important;
  }
  
  .mcp-marketplace .mcp-github-link:hover {
    color: #0056b3 !important;
  }
  
  .mcp-marketplace .mcp-no-results,
  .mcp-marketplace .mcp-loading {
    color: #6c757d !important;
  }
}

/* Section header with action button */
.section-header-with-action {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}

.section-header-with-action h3 {
  margin: 0 0 8px 0;
  font-size: 18px;
  font-weight: 600;
  color: #495057;
  border-bottom: 2px solid #007acc;
  padding-bottom: 8px;
}

.section-header-with-action p {
  margin: 8px 0 0 0;
  color: #6c757d;
  font-size: 14px;
}

.refresh-mcp-btn {
  background-color: #007acc;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  margin-left: 16px;
  margin-top: -4px;
}

.refresh-mcp-btn:hover:not(:disabled) {
  background-color: #0056b3;
  transform: translateY(-1px);
}

.refresh-mcp-btn:active {
  transform: translateY(0);
}

.refresh-mcp-btn:disabled {
  background-color: #6c757d;
  cursor: not-allowed;
  opacity: 0.6;
}

/* MCP message styles for dark mode */
@media (prefers-color-scheme: dark) {
  .mcp-marketplace .mcp-message.success {
    background-color: #ecfdf5 !important;
    color: #065f46 !important;
    border-color: #a7f3d0 !important;
  }
  
  .mcp-marketplace .mcp-message.error {
    background-color: #fef2f2 !important;
    color: #991b1b !important;
    border-color: #fecaca !important;
  }
  
  .mcp-marketplace .mcp-message.info {
    background-color: #eff6ff !important;
    color: #1e40af !important;
    border-color: #93c5fd !important;
  }
}

/* Responsive design for MCP */
@media (max-width: 768px) {
  .mcp-controls {
    flex-direction: column;
    align-items: stretch;
  }
  
  .mcp-search {
    min-width: auto;
  }
  
  .mcp-filter {
    min-width: auto;
  }
  
  .mcp-server-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .mcp-server-actions {
    align-self: stretch;
  }
  
  .mcp-connect-btn,
  .mcp-disconnect-btn {
    width: 100%;
  }
  
  .mcp-server-details {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* Gmail Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
}

.gmail-modal {
  max-width: 550px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px 16px 24px;
  border-bottom: 1px solid #e9ecef;
}

.modal-header h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: #2c3e50;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 24px;
  color: #6c757d;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.modal-close-btn:hover {
  background-color: #f8f9fa;
  color: #495057;
}

.modal-body {
  padding: 24px;
}

.gmail-modal-description {
  margin: 0 0 20px 0;
  color: #495057;
  font-size: 14px;
  line-height: 1.5;
}

.gmail-setup-steps {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 24px;
}

.gmail-setup-steps ol {
  margin: 0;
  padding-left: 20px;
  color: #495057;
  font-size: 13px;
  line-height: 1.6;
}

.gmail-setup-steps li {
  margin-bottom: 8px;
}

.gmail-setup-steps li:last-child {
  margin-bottom: 0;
}

.gmail-setup-steps a {
  color: #007acc;
  text-decoration: none;
}

.gmail-setup-steps a:hover {
  text-decoration: underline;
}

.gmail-setup-steps code {
  background-color: #e9ecef;
  padding: 2px 4px;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
  font-size: 12px;
}

.gmail-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-weight: 500;
  color: #495057;
  font-size: 14px;
}

.gmail-input {
  width: 100%;
  padding: 12px;
  border: 2px solid #e1e5e9;
  border-radius: 8px;
  font-size: 14px;
  background-color: #ffffff !important;
  color: #1a1a1a !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-sizing: border-box;
  caret-color: #007acc;
  line-height: 1.4;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  -webkit-text-fill-color: #1a1a1a !important;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.gmail-input:-webkit-autofill,
.gmail-input:-webkit-autofill:hover,
.gmail-input:-webkit-autofill:focus {
  background-color: #ffffff !important;
  -webkit-text-fill-color: #1a1a1a !important;
  box-shadow: 0 0 0px 1000px #ffffff inset !important;
}

.gmail-input:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.1);
  caret-color: #007acc;
}

.gmail-input::placeholder {
  color: #6c757d;
  font-style: italic;
  opacity: 0.8;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  padding: 16px 24px 24px 24px;
  border-top: 1px solid #e9ecef;
}

.modal-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 100px;
}

.modal-btn.secondary {
  background-color: #6c757d;
  color: white;
}

.modal-btn.secondary:hover:not(:disabled) {
  background-color: #5a6268;
  transform: translateY(-1px);
}

.modal-btn.primary {
  background-color: #007acc;
  color: white;
}

.modal-btn.primary:hover:not(:disabled) {
  background-color: #0056a3;
  transform: translateY(-1px);
}

.modal-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

/* Light theme for Gmail modal in dark mode */
@media (prefers-color-scheme: dark) {
  .modal-content {
    background-color: #ffffff;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  }
  
  .modal-header {
    border-bottom-color: #e9ecef;
  }
  
  .modal-header h3 {
    color: #2c3e50;
  }
  
  .modal-close-btn {
    color: #6c757d;
  }
  
  .modal-close-btn:hover {
    background-color: #f8f9fa;
    color: #495057;
  }
  
  .gmail-modal-description {
    color: #495057;
  }
  
  .gmail-setup-steps {
    background-color: #f8f9fa;
  }
  
  .gmail-setup-steps ol {
    color: #495057;
  }
  
  .gmail-setup-steps a {
    color: #007acc;
  }
  
  .gmail-setup-steps code {
    background-color: #e9ecef;
    color: #495057;
  }
  
  .form-group label {
    color: #495057;
  }
  
  .gmail-input {
    background-color: #ffffff !important;
    border-color: #ced4da;
    color: #495057 !important;
    caret-color: #007acc;
    -webkit-text-fill-color: #495057 !important;
  }
  
  .gmail-input:focus {
    border-color: #007acc;
    box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.1);
    caret-color: #007acc;
  }
  
  .gmail-input::placeholder {
    color: #6c757d;
    opacity: 0.8;
  }
  
  .modal-footer {
    border-top-color: #e9ecef;
  }
  
  .modal-btn.secondary {
    background-color: #6c757d;
  }
  
  .modal-btn.secondary:hover:not(:disabled) {
    background-color: #5a6268;
  }

  .gmail-input:-webkit-autofill,
  .gmail-input:-webkit-autofill:hover,
  .gmail-input:-webkit-autofill:focus {
    background-color: #ffffff !important;
    -webkit-text-fill-color: #495057 !important;
    box-shadow: 0 0 0px 1000px #ffffff inset !important;
  }
}

/* User Selector Dropdown Styles */
.user-selector-container {
  position: relative;
  max-width: 300px;
}

.user-selector-with-add {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.user-selector-dropdown {
  position: relative;
  background-color: #ffffff;
  border: 1px solid #ced4da;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 0.2s ease;
  flex: 1;
}

.user-selector-dropdown:hover {
  border-color: #007acc;
}

.user-selector-dropdown.open {
  border-color: #007acc;
  z-index: 10;
}

.user-selector-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
}

.current-user-display {
  flex: 1;
  font-size: 14px;
  color: #495057;
}

.user-details-mini {
  color: #6c757d;
  font-weight: normal;
  margin-left: 4px;
}

.loading-text {
  color: #6c757d;
  font-style: italic;
}

.no-user-selected {
  color: #6c757d;
  font-style: italic;
}

.dropdown-arrow {
  font-size: 12px;
  color: #6c757d;
  margin-left: 8px;
}

.user-dropdown-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: #ffffff;
  border: 1px solid #ced4da;
  border-top: none;
  border-radius: 0 0 6px 6px;
  max-height: 150px;
  overflow-y: auto;
  z-index: 20;
}

.user-dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  cursor: pointer;
  border-bottom: 1px solid #f1f3f4;
}

.user-dropdown-item:last-child {
  border-bottom: none;
}

.user-dropdown-item:hover {
  background-color: #f8f9fa;
}

.user-dropdown-item.selected {
  background-color: #e9ecef;
}

.user-dropdown-info {
  flex: 1;
}

.user-dropdown-name {
  font-size: 14px;
  color: #495057;
}

.user-dropdown-details {
  color: #6c757d;
  font-size: 12px;
}

.selected-indicator {
  color: #007acc;
  font-size: 12px;
  margin-left: 8px;
}

.no-users-dropdown {
  padding: 12px;
  text-align: center;
  color: #6c757d;
  font-style: italic;
}

/* Add User Button */
.add-user-button {
  background-color: #28a745;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.add-user-button:hover {
  background-color: #218838;
}

/* Add User Modal */
.add-user-modal {
  max-width: 400px;
}

.add-user-description {
  margin: 0 0 20px 0;
  color: #495057;
  font-size: 14px;
  line-height: 1.5;
}

.add-user-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.add-user-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
  background-color: #ffffff;
  color: #495057;
  transition: border-color 0.2s ease;
  box-sizing: border-box;
}

.add-user-input:focus {
  outline: none;
  border-color: #007acc;
}

.add-user-input::placeholder {
  color: #6c757d;
  font-style: italic;
}

/* Light theme for user selector in dark mode */
@media (prefers-color-scheme: dark) {
  .user-selector-dropdown {
    background-color: #ffffff;
    border-color: #ced4da;
  }

  .user-selector-dropdown:hover {
    border-color: #007acc;
  }

  .current-user-display {
    color: #495057;
  }

  .user-details-mini {
    color: #6c757d;
  }

  .loading-text,
  .no-user-selected {
    color: #6c757d;
  }

  .dropdown-arrow {
    color: #6c757d;
  }

  .user-dropdown-list {
    background-color: #ffffff;
    border-color: #ced4da;
  }

  .user-dropdown-item {
    border-bottom-color: #f1f3f4;
  }

  .user-dropdown-item:hover {
    background-color: #f8f9fa;
  }

  .user-dropdown-item.selected {
    background-color: #e9ecef;
  }

  .user-dropdown-name {
    color: #495057;
  }

  .user-dropdown-details {
    color: #6c757d;
  }

  .selected-indicator {
    color: #007acc;
  }

  .no-users-dropdown {
    color: #6c757d;
  }

  .add-user-modal {
    background-color: #ffffff;
  }

  .add-user-description {
    color: #495057;
  }

  .add-user-input {
    background-color: #ffffff;
    border-color: #ced4da;
    color: #495057;
  }

  .add-user-input:focus {
    border-color: #007acc;
  }

  .add-user-input::placeholder {
    color: #6c757d;
  }
}

/* Responsive design for user selector */
@media (max-width: 768px) {
  .user-selector-container {
    max-width: 100%;
  }

  .user-selector-with-add {
    flex-direction: column;
    gap: 8px;
  }

  .add-user-button {
    align-self: flex-start;
  }
} 